#include<stdio.h>

struct identification /* Global structure template. */
{
	char name[21];
	float height;
	float weight;
	char hair_colour[11];
	char eye_colour[11];
 } ;
 struct identification id; /* Global structure template. */
 
void input_data(struct identification *id); /* pass by reference*/ 
void display_data(const struct identification id); /* pass by value*/
 
int main()
{
	/* Use a pointer to a structure variable as an argument.*/
	input_data(&id);
	
	/* Use a structure variable as an argument.*/
	display_data(id); 
	return 0;
}

/* Function :input_data()
   Purpose  :This function reads data.
   Parameter:A pointer to the data structure. */
void input_data(struct identification*id)
{
	printf("Please input your name:");
	scanf("%20s",id->name);
	printf("\nPlease input your height:");
	scanf("%f",&(id->height));
	printf("\nPlease input your weight:");
	scanf("%f",&(id->weight));
	printf("\nPlease input your hair_colour:");
	scanf("%10s",id->hair_colour);
	printf("\nPlease input your eye_colour:");
	scanf("%10s",id->eye_colour);
}

/* Function : display_data()
   Purpose  :This function displays data.
   Parameter:The data. */ 
void display_data(const struct identification id)
{
	printf("\nname:%s",id.name);
	printf("\nheight:%f",id.height);
	printf("\nweight:%f",id.weight);
	printf("\nhair_colour:%10s",id.hair_colour);
	printf("\neye_colour:%10s",id.eye_colour);
}
